<template>
	<view class="page">
		<!-- <view class="flex benben-position-layout flex flex-wrap align-center testExamination_flex_0"
			:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx'}">
			<view class='flex flex-wrap align-center justify-between flex-sub testExamination_fd0_0'>
				<view class='flex flex-wrap align-center' @tap.stop="handleJumpDiy" data-type="back" data-url="1">
					<text class='fu-iconfont2  testExamination_fd0_0_c0_c0'>&#xE794;</text>
				</view>
				<text class='testExamination_fd0_0_c1'>选择时间</text>
				<view class='flex flex-wrap align-center testExamination_fd0_0_c2'>
				</view>
			</view>
		</view>
		<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view> -->
		<view class="loading_css" v-if="isShow">
			<u-loading size="36" color="#FC5B03"></u-loading>
			<view>加载中</view>
		</view>
		<template v-else>
			<view class="calendar">
				<calendar ref="calendar" @cancel="cancel" :startDate="startDate" :height="height" :endDate="endDate"
					@selectDate="selectDate" :limit="limit" :bottom1="bottom1" :yimanArray="yimanArray" />
			</view>
		</template>
		

		<!-- <view class="flex align-center justify-between feedback_flex_4">
			<view class='feedback_fd4_0'>提交</view>
		</view> -->
	</view>
</template>
<script>
	import calendar from '../components/dc-calendar/dc-calendar.vue'
	import utils from "@/common/utils/utils.js"
	export default {
		components: {
			calendar
		},

		data() {
			return {
				isShow: true,
				startDate: '', //开始日期2022-01-26
				endDate: '', //结束日期 2022-01-29
				height: 600, //日历容器高度
				limit: 3, //展示月份数量
				bottom1: 0,
				yimanArray: [],
				dicdes: {
					price: 1
				}, //传过来的订单数据
				type: 0, //1是进入订单 0是返回
				timeData: {},
			};
		},
		computed: {

		},
		watch: {},
		onLoad(options) {
			
		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {
			if (global.timeData) {
				this.startDate = global.timeData.toDay.substring(0, 10);
				this.endDate = global.timeData.twoDay.substring(0, 10);
			}
			setTimeout(() => {
				this.isShow = false;
			}, 300)
		},
		onHide() {

		},
		onResize() {

		},
		onPullDownRefresh() {

		},
		onReachBottom(e) {

		},
		onPageScroll(e) {

		},
		methods: {
			selectDate(e) {
				// console.log(e);
				let toDay = e.startDate;
				let week = utils.getWeekday(toDay);
				let twoDay = e.endDate;
				let twoWeek = utils.getWeekday(twoDay);
				this.timeData = {
					dayNum: e.dayNum,
					is_today: e.startDate == utils.getNowTime() ? 1 : 0,
					toDay: toDay,
					toDay_month: (toDay.substring(5, 10)).replace('-', '月') + '日',
					toDay_time: toDay.substring(11, 16),
					week: week,
					twoDay: twoDay,
					twoDay_month: (twoDay.substring(5, 10)).replace('-', '月') + '日',
					twoDay_time: twoDay.substring(11, 16),
					twoWeek: twoWeek
				}
				global.timeData = this.timeData;
				uni.$emit('changeTime');
				uni.navigateBack();
			}
		}
	};
</script>
<style lang="scss" scoped>
	.success_content {
		text-align: center;
	}

	.success_icon {
		width: 480rpx;
		height: 380rpx;
		margin: 80rpx 0 24rpx;
	}

	.tip_text {
		text-align: center;
		font-weight: bold;
		font-size: 36rpx;
		color: #111111;
	}

	.task {
		margin: 66rpx 116rpx 100rpx 80rpx;

		.task_le {
			display: flex;
			flex-direction: column;
			align-items: center;

			.task_le_1 {
				width: 24rpx;
				height: 24rpx;
				border-radius: 20rpx;
				border: 2rpx solid #CCCCCC;
				border-radius: 50%;
			}

			.task_le_2 {
				width: 2px;
				height: 136rpx;
				background: #F7F7F7;
				border-radius: 20rpx;
			}
		}

		.task_ri {
			margin-left: 30rpx;

			.task_ri_t {
				text-align: left;

				.ri_t_1 {
					font-weight: bold;
					font-size: 30rpx;
					color: #111111;
				}

				.ri_t_2 {
					font-weight: 400;
					font-size: 26rpx;
					color: #999999;
					margin-top: 4rpx;
					line-height: 30rpx;
				}
			}

			.task_ri_t_m {
				margin-top: 78rpx;
			}
		}
	}

	.personalInformation_fd1_0 {
		padding: 28rpx 0;
		border-top: 2rpx solid #eee;
	}

	.personalInformation_fd1_0_c0 {
		font-size: 28rpx;
		color: rgba(0, 0, 0, 0.6);
	}

	.personalInformation_fd1_1_c1 {
		font-size: 28rpx;
		font-weight: 400;
		color: #111;
		text-align: right;
	}


	.feedback_fd4_0 {
		width: 640rpx;
		border-radius: 80rpx;
		font-size: 30rpx;
		font-weight: bold;
		color: #fff;
		margin: 0rpx 55rpx 0rpx 55rpx;
		height: 84rpx;
		line-height: 84rpx;
		text-align: center;
		background: #FC5B03;
	}

	.feedback_flex_4 {
		width: 750rpx;
		height: 120rpx;
		overflow: hidden;
		position: fixed;
		z-index: 10;
		bottom: calc(0rpx + var(--window-bottom));
		display: flex;
		justify-content: center;
		background: #fff;
	}




	.testExamination_fd1_0 {
		margin: 0rpx 16rpx 0rpx 0rpx;
		padding: 40rpx 32rpx 24rpx 32rpx;
	}

	.testExamination_fd1_0_c0 {
		width: 36rpx;
		height: 36rpx;
		margin: 0rpx 16rpx 0rpx 0rpx;
	}

	.testExamination_fd1_0_c1 {
		line-height: 45rpx;
		font-size: 32rpx;
		font-weight: 700;
		color: #333333;
	}

	.testExamination_notAnfd1_1_c0 {
		background: rgba(244, 250, 255, 1);
		background-size: 100% !important;
		width: 750rpx;
		height: 80rpx;
		border-radius: 40rpx 40rpx 40rpx 40rpx;
		padding: 0rpx 32rpx 0rpx 32rpx;
	}

	.testExamination_anfd1_1_c0 {
		background: rgba(244, 250, 255, 1);
		background-size: 100% !important;
		border-radius: 40rpx 40rpx 40rpx 40rpx;
		padding: 0rpx 32rpx 0rpx 32rpx;
		width: 750rpx;
		height: 80rpx;
	}

	.testExamination_areafd1_1_c0 {
		min-height: 80rpx;
		padding: 0rpx 32rpx 0rpx 32rpx;
	}

	.testExamination_notAnfd1_1_c0_c0_c0 {
		width: 36rpx;
		height: 36rpx;
		margin: 0rpx 16rpx 0rpx 0rpx;
	}

	.testExamination_notAnfd1_1_c0_c0_c1 {
		margin: 0rpx 20rpx 0rpx 0rpx;
		line-height: 45rpx;
		font-size: 32rpx;
		font-weight: 700;
		color: #1593FF;
	}

	.testExamination_notAnfd1_1_c0_c0_c2 {
		font-weight: 700;
		font-size: 32rpx;
		color: #1593FF;
		line-height: 45rpx;
		text-decoration: none;
		-webkit-line-clamp: 1;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
	}

	.testExamination_anfd1_1_c0_c0_c0 {
		width: 36rpx;
		height: 36rpx;
		margin: 0rpx 16rpx 0rpx 0rpx;
	}

	.testExamination_anfd1_1_c0_c0_c1 {
		margin: 0rpx 20rpx 0rpx 0rpx;
		line-height: 45rpx;
		font-size: 32rpx;
		font-weight: 700;
		color: #1593FF;
	}

	.testExamination_anfd1_1_c0_c0_c2 {
		font-weight: 700;
		font-size: 32rpx;
		color: #1593FF;
		line-height: 45rpx;
		text-decoration: none;
		-webkit-line-clamp: 1;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
	}

	.testExamination_areafd1_1_c0_c0 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 40rpx 0rpx;
	}

	.testExamination_areafd1_1_c0_c0_c0 {
		margin: 0rpx 0rpx 24rpx 0rpx;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c0 {
		margin: 0rpx 0rpx 24rpx 0rpx;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c0_c0 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
		margin: 0rpx 15rpx 0rpx 0rpx;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c0_c1 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c0 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: rgba(21, 147, 255, 1);
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c1 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c2 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c3 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
		margin: 0rpx 32rpx 0rpx 0rpx;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c4 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
	}

	.testExamination_areafd1_1_c0_c0_c0_c0_c1_c5 {
		line-height: 40rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333333;
	}

	.testExamination_areafd1_1_c0_c0_c0_c1 {
		font-size: 26rpx;
		color: rgba(191, 191, 191, 1);
	}

	.testExamination_areafd1_1_c0_c0_c1 {
		background: rgba(242, 242, 242, 1);
		background-size: 100% !important;
		width: 602rpx;
		height: 16rpx;
		border-radius: 16rpx 16rpx 16rpx 16rpx;
		background-size: 100% auto !important;
	}

	.testExamination_progress1_areafd1_1_c0_c0_c1 {
		background: rgba(21, 147, 255, 1);
		background-size: 100% !important;
		border-radius: 10rpx 10rpx 10rpx 10rpx;
	}

	.testExamination_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		height: 88rpx;
	}

	.testExamination_fd0_0_c0_c0 {
		font-size: 32rpx;
		font-weight: 500;
		color: #111;
	}

	.testExamination_fd0_0_c1 {
		font-size: 32rpx;
		font-weight: bold;
		color: #111111;
	}

	.testExamination_fd0_0_c2 {
		width: 36rpx;
		height: 36rpx;
	}

	.testExamination_flex_0 {
		border-bottom: 1px solid #eee;
		background: #fff;
		background-size: 100% !important;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
	}

	.page {
		min-height: calc(100vh - var(--window-bottom));
		background: #fff;
		background-size: 100% auto !important;
	}
</style>